From: Ben Hutchings Date: Wed, 13 Apr 2016 20:48:06 +0000 (+0100) Subject: fs: Add MODULE_SOFTDEP declarations for hard-coded crypto drivers X-Git-Tag: archive/raspbian/4.9.13-1+rpi1~11^2~67 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https://%22Program/%22http:/www.example.com/cgi/%22https:/%22Program?a=commitdiff_plain;h=4abdd25fc4cf500969e5c8a74bbd9f9c672799fe;p=linux-4.9.git fs: Add MODULE_SOFTDEP declarations for hard-coded crypto drivers This helps initramfs builders and other tools to find the full dependencies of a module. Signed-off-by: Ben Hutchings Gbp-Pq: Topic bugfix/all Gbp-Pq: Name fs-add-module_softdep-declarations-for-hard-coded-cr.patch --- diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c index 74ed5aae6cea..a878a6338a38 100644 --- a/fs/btrfs/super.c +++ b/fs/btrfs/super.c @@ -2491,3 +2491,4 @@ late_initcall(init_btrfs_fs); module_exit(exit_btrfs_fs) MODULE_LICENSE("GPL"); +MODULE_SOFTDEP("pre: crypto-crc32c"); diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c index 15261ba464c5..61308acdf514 100644 --- a/fs/cifs/cifsfs.c +++ b/fs/cifs/cifsfs.c @@ -1366,5 +1366,13 @@ MODULE_DESCRIPTION ("VFS to access servers complying with the SNIA CIFS Specification " "e.g. Samba and Windows"); MODULE_VERSION(CIFS_VERSION); + +#ifdef CONFIG_CIFS_SMB2 +#define CIFS_SMB2_EXTRA_SOFTDEPS " crypto-aes crypto-cmac crypto-sha256" +#else +#define CIFS_SMB2_EXTRA_SOFTDEPS "" +#endif +MODULE_SOFTDEP("pre: crypto-arc4 crypto-des crypto-ecb crypto-hmac crypto-md4 crypto-md5" CIFS_SMB2_EXTRA_SOFTDEPS); + module_init(init_cifs) module_exit(exit_cifs) diff --git a/fs/crypto/crypto.c b/fs/crypto/crypto.c index 98f87fe8f186..c345fb7be1db 100644 --- a/fs/crypto/crypto.c +++ b/fs/crypto/crypto.c @@ -567,3 +567,4 @@ static void __exit fscrypt_exit(void) module_exit(fscrypt_exit); MODULE_LICENSE("GPL"); +MODULE_SOFTDEP("pre: crypto-aes crypto-ecb"); diff --git a/fs/ext4/super.c b/fs/ext4/super.c index bbc316db9495..a883d631deca 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -5663,5 +5663,13 @@ static void __exit ext4_exit_fs(void) MODULE_AUTHOR("Remy Card, Stephen Tweedie, Andrew Morton, Andreas Dilger, Theodore Ts'o and others"); MODULE_DESCRIPTION("Fourth Extended Filesystem"); MODULE_LICENSE("GPL"); + +#ifdef CONFIG_EXT4_FS_ENCRYPTION +#define EXT4_ENC_EXTRA_SOFTDEPS " crypto-aes crypto-ecb" +#else +#define EXT4_ENC_EXTRA_SOFTDEPS "" +#endif +MODULE_SOFTDEP("pre: crypto-crc32c" EXT4_ENC_EXTRA_SOFTDEPS); + module_init(ext4_init_fs) module_exit(ext4_exit_fs) diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 013c6a541d6b..c949ca1ab229 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -2033,3 +2033,4 @@ module_exit(exit_f2fs_fs) MODULE_AUTHOR("Samsung Electronics's Praesto Team"); MODULE_DESCRIPTION("Flash Friendly File System"); MODULE_LICENSE("GPL"); +MODULE_SOFTDEP("pre: crypto-crc32c"); diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c index 927da4956a89..6155fe57a03b 100644 --- a/fs/jbd2/journal.c +++ b/fs/jbd2/journal.c @@ -2673,6 +2673,7 @@ static void __exit journal_exit(void) } MODULE_LICENSE("GPL"); +MODULE_SOFTDEP("pre: crypto-crc32c"); module_init(journal_init); module_exit(journal_exit); diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index 36b2af931e06..2ecdd6f912d8 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -1308,5 +1308,8 @@ static void __exit exit_nfsd(void) MODULE_AUTHOR("Olaf Kirch "); MODULE_LICENSE("GPL"); +#ifdef CONFIG_NFSD_V4 +MODULE_SOFTDEP("pre: crypto-md5"); +#endif module_init(init_nfsd) module_exit(exit_nfsd)